setting up events in editor x